package com.example.admin.yuejian_22;

import android.content.Intent;
import android.support.annotation.Nullable;
import android.os.Bundle;
import android.view.View;
import android.widget.Button;

import com.example.admin.yuejian_22.Activity.HomeActivity;
import com.example.admin.yuejian_22.Activity.LoginActivity;
import com.example.admin.yuejian_22.Base.BaseActivity;
public class MainActivity extends BaseActivity {
    private Button button_login;
    @Override
    public View onViewCreated(View view, @Nullable Bundle savedInstanceState) {
        return view;
    }

    @Override
    protected void onCreate( Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_main);
        initViews();
        initEvents();
    }

    public void initViews()
    {
        button_login=(Button)findViewById(R.id.button_login);
    }
    public void initEvents(){
        button_login = (Button) findViewById(R.id.button_login);
        button_login.setOnClickListener(new View.OnClickListener() {
            @Override
            public void onClick(View view) {
                Intent intent = new Intent(MainActivity.this, LoginActivity.class);
                startActivity(intent);
            }
        });
    }
}















